#define _CRT_SECURE_NO_WARNINGS 1
class Solution {
public:
    bool isUnique(string astr) {
        int num = 0;
        if (astr.size() > 26)
            return false;
        for (auto x : astr) {
            int i = x - 'a';
            if (((num >> i) & 1) == 1)
                return false;
            num |= 1 << i;
        }
        return true;
    }
};